home *** CD-ROM | disk | FTP | other *** search
/ SPACE 2 / SPACE - Library 2 - Volume 1.iso / apps / 165 / applic / c64xpand.s < prev    next >
Encoding:
Text File  |  1987-08-18  |  840 b   |  35 lines

  1. ; Decompress JJ and GG Commodore 64 pictures
  2. ; ***** Jerry Bethel  July 27, 1987 *****
  3. ; get the input area and length, and  output area
  4. init0:
  5.    move.l  6(sp),a0
  6.    lea     init0,a1
  7.    cmp.l   0(a0),a1          ; Old version parm list?
  8.    beq     init1             ; Yes, go process
  9.    move.l  0(a0),a1          ; New version parm offsets
  10.    move.l  4(a0),a2          ; (Same as Atari ST-Basic)
  11.    move.l  8(a0),d3
  12.    bra     init2
  13. init1:
  14.    move.l  4(a0),a1          ; Old parm offsets
  15.    move.l  8(a0),a2
  16.    move.l  12(a0),d3
  17. init2:
  18. main00:
  19.    cmp.b   #$fe,0(a1)
  20.    beq     main10
  21.    move.b  (a1)+,(a2)+
  22.    dbf     d3,main00
  23.    rts
  24. main10:
  25.    clr.l   d1
  26.    move.b  2(a1),d1
  27.    subq.l  #1,d1
  28. main20:
  29.    move.b  1(a1),(a2)+
  30.    dbf     d1,main20
  31.    addq.l  #3,a1
  32.    subq.l  #3,d3
  33.    bra     main00
  34.    end
  35.